

import Vue from "vue"
import VueRouter from "vue-router"
import Index from "../components/layout/index.vue";


const routes = [
    {
        path: '/',
        name: 'index',
        component: Index,
        redirect: 'mapIndex',
        //路由嵌套
        children: [
            // { path: '/index/main', name: 'main', component: () => import('../components/main/index.vue') },
            { path: '/index/mapIndex', name: 'mapIndex', component: () => import('../components/mapIndex/index.vue') },
            { path: '/index/mapView', name: 'mapView', component: () => import('../components/mapView/index.vue') },
            { path: '/index/mapModel-3dTiles', name: 'mapModel-3dTiles', component: () => import('../components/mapModel/index-3dTiles.vue') },
            { path: '/index/mapModel-gltf', name: 'mapModel-gltf', component: () => import('../components/mapModel/index-gltf.vue') },
            { path: '/index/mapModel-geojson', name: 'mapModel-geojson', component: () => import('../components/mapModel/index-geojson.vue') },
            { path: '/index/mapEffect-heatmap1', name: 'mapEffect-heatmap1', component: () => import('../components/mapEffect/index-heatmap1.vue') },
            { path: '/index/mapEffect-heatmap2', name: 'mapEffect-heatmap2', component: () => import('../components/mapEffect/index-heatmap2.vue') },
            { path: '/index/mapEffect-water', name: 'mapEffect-water', component: () => import('../components/mapEffect/index-water.vue') },

            { path: '/index/mapEntity-baseData', name: 'mapEffect-baseData', component: () => import('../components/mapEntity/index-baseData.vue') },
            { path: '/index/mapEntity-PrimitivePoint', name: 'mapEffect-PrimitivePoint', component: () => import('../components/mapEntity/index-PrimitivePoint.vue') }


        ]
    }]

const router = new VueRouter({
    mode: "history",
    base: "/",
    routes
})

export default router